package cn.wzx.entity;

import java.util.Date;

public class Book {
    private Integer id; // 书本ID
    private String sn; // 编号
    private String name; // 名称
    private Double price; // 价格
    private String author; // 作者
    private String publisher; // 出版社
    private Date tpublish; // 日期
    private String picture; // 图片
    private BookType bookType; // 书本类型
    private int rate; // 点赞数
    private int salenum; // 销量
    private int favnum; // 添加到购物车数量

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getSn() {
        return sn;
    }

    public void setSn(String sn) {
        this.sn = sn;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public String getPublisher() {
        return publisher;
    }

    public void setPublisher(String publisher) {
        this.publisher = publisher;
    }

    public Date getTpublish() {
        return tpublish;
    }

    public void setTpublish(Date tpublish) {
        this.tpublish = tpublish;
    }

    public String getPicture() {
        return picture;
    }

    public void setPicture(String picture) {
        this.picture = picture;
    }

    public BookType getBookType() {
        return bookType;
    }

    public void setBookType(BookType bookType) {
        this.bookType = bookType;
    }

    public int getRate() {
        return rate;
    }

    public void setRate(int rate) {
        this.rate = rate;
    }

    public int getSalenum() {
        return salenum;
    }

    public void setSalenum(int salenum) {
        this.salenum = salenum;
    }

    public int getFavnum() {
        return favnum;
    }

    public void setFavnum(int favnum) {
        this.favnum = favnum;
    }

    @Override
    public String toString() {
        return "Book{" +
                "id=" + id +
                ", sn='" + sn + '\'' +
                ", name='" + name + '\'' +
                ", price=" + price +
                ", author='" + author + '\'' +
                ", publisher='" + publisher + '\'' +
                ", tpublish=" + tpublish +
                ", picture='" + picture + '\'' +
                ", bookType=" + bookType +
                ", rate=" + rate +
                ", salenum=" + salenum +
                ", favnum=" + favnum +
                '}';
    }
}
